package com.dt76.smallloanbackenduser.remote.xiaohao;


import com.dt76.smallloanbackenduser.hystrix.xiaohao.CheckStateHystrix;
import com.dt76.smallloanbackenduser.pojo.xiaohao.CheckState;
import org.springframework.cloud.netflix.feign.FeignClient;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;

import java.util.List;

@FeignClient(name="smallloan-backend-service",fallback = CheckStateHystrix.class)
public interface CheckStateRemote {

    @RequestMapping("/xiaohao/CheckState/qryAllCheckStateByID")
    List<CheckState> qryAllCheckStateByID(@RequestParam("id") int id);

    @PostMapping(value = "/xiaohao/CheckState/addCheckState",consumes = "application/json")
    int addCheckState(@RequestBody CheckState checkState);
}
